import Mock from 'mockjs'

export enum ByteType {
  Byte = 1
  // 可以添加更多的字节类型值
}
export interface StudentInfoVO {
  id: number
  name: string
  phone: string
  gender: ByteType
  carType: ByteType
  memberId: number
}

// 删除学员信息
export const deleteStudentInfo = async (id: number) => {
  return '删除'
}

// 查询学员信息详情
export const getStudentInfo = async (id: number) => {
  return '查询res'
}

// 查询学员信息列表
export const getStudentInfoPage = async (params) => {
  return await Mock.mock({
    'list|10': [
      {
        'id|+1': 1,
        name: '@cname',
        phone: 130888888,
        gender: 1,
        carType: 1,
        memberId: '@id',
        tenantId: '@id',
        creator: '@cname',
        createTime: '@date',
        updater: '@cname',
        deleted: '@date',
        updateTime: '@date',
        formLoading: 'true'
      }
    ]
  })
}

// 导出学员信息 Excel
export const exportStudentInfo = async (params) => {
  return '导出res'
}

// 修改学员信息
export const updateStudentInfo = async (data: StudentInfoVO) => {
  return '修改res'
}

// 新增学员信息
export const createStudentInfo = async (data: StudentInfoVO) => {
  return '新增res'
}
